package Controller;
import Model.*;
import java.util.*;

public class CustomerCtr
{
    
    
    public CustomerCtr()
    {
        CustomerCont.getInstance();
        
    }

    public static void AddCustomer(Customer c)
    {
        CustomerCont.getInstance().addCustomer(c);
    }    
    
    public static void DeleteCustomer(String theID)
   {
       for(int i=0;i<CustomerCont.getCont().size();i++)
       {
           if(CustomerCont.getCont().get(i).getID()==theID)CustomerCont.getCont().remove(i);
        }
   }
    
   public static void SearchCustomer(String theID)
   {
       for(int i=0;i<CustomerCont.getCont().size();i++)
       {
           if(CustomerCont.getCont().get(i).getID()==theID)System.out.println("Customer exists");
           else System.out.println("Customer doesn`t exist");
        }
    }
}
    